#ifndef __FLASH_WRITE_READ_H
#define __FLASH_WRITE_READ_H

#include "stm32f10x.h"

void flash_write_4byte(uint32_t address,uint32_t *buf,uint16_t length);
uint32_t flash_read_4byte(uint32_t address);
void flash_write_2byte(uint32_t address,uint16_t *buf,uint16_t length);
uint16_t flash_read_2byte(uint32_t address);
uint8_t flash_read_byte(uint32_t address);

void flash_erase_page(uint32_t address);

void transfer_page_data(uint32_t raw_address,uint32_t goal_address,uint16_t data_size);

#endif 
